{
 "cells": [
  {
   "cell_type": "markdown",
   "id": "45b8ffbf",
   "metadata": {},
   "source": [
    "## 搜索poi2.0"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "id": "e33a50e7",
   "metadata": {},
   "outputs": [],
   "source": [
    "# key：f7b3c94b56fe002e2b98f6bb8d8a5f46"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "id": "7d06a726",
   "metadata": {},
   "outputs": [],
   "source": [
    "import requests\n",
    "\n",
    "POI_url = 'https://restapi.amap.com/v3/place/text?parameters'\n",
    "\n",
    "payload = {\n",
    "    'key':'f7b3c94b56fe002e2b98f6bb8d8a5f46',\n",
    "    'keywords':'喜茶',\n",
    "    'extensions':'all',\n",
    "    \n",
    "}\n",
    "\n",
    "r = requests.get(url=POI_url, params=payload )"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "id": "cb32b4a9",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'suggestion': {'keywords': [],\n",
       "  'cities': [{'citycode': '0755',\n",
       "    'adcode': '440300',\n",
       "    'num': '461',\n",
       "    'name': '深圳市'},\n",
       "   {'citycode': '020', 'adcode': '440100', 'num': '460', 'name': '广州市'},\n",
       "   {'citycode': '028', 'adcode': '510100', 'num': '265', 'name': '成都市'},\n",
       "   {'citycode': '021', 'adcode': '310000', 'num': '265', 'name': '上海市'},\n",
       "   {'citycode': '0769', 'adcode': '441900', 'num': '225', 'name': '东莞市'},\n",
       "   {'citycode': '023', 'adcode': '500000', 'num': '223', 'name': '重庆市'},\n",
       "   {'citycode': '0757', 'adcode': '440600', 'num': '195', 'name': '佛山市'},\n",
       "   {'citycode': '010', 'adcode': '110000', 'num': '192', 'name': '北京市'},\n",
       "   {'citycode': '0752', 'adcode': '441300', 'num': '132', 'name': '惠州市'},\n",
       "   {'citycode': '0731', 'adcode': '430100', 'num': '125', 'name': '长沙市'},\n",
       "   {'citycode': '0750', 'adcode': '440700', 'num': '123', 'name': '江门市'},\n",
       "   {'citycode': '0571', 'adcode': '330100', 'num': '109', 'name': '杭州市'},\n",
       "   {'citycode': '0595', 'adcode': '350500', 'num': '106', 'name': '泉州市'},\n",
       "   {'citycode': '022', 'adcode': '120000', 'num': '101', 'name': '天津市'},\n",
       "   {'citycode': '027', 'adcode': '420100', 'num': '96', 'name': '武汉市'},\n",
       "   {'citycode': '029', 'adcode': '610100', 'num': '91', 'name': '西安市'},\n",
       "   {'citycode': '0532', 'adcode': '370200', 'num': '90', 'name': '青岛市'},\n",
       "   {'citycode': '025', 'adcode': '320100', 'num': '90', 'name': '南京市'},\n",
       "   {'citycode': '0592', 'adcode': '350200', 'num': '86', 'name': '厦门市'},\n",
       "   {'citycode': '0754', 'adcode': '440500', 'num': '85', 'name': '汕头市'},\n",
       "   {'citycode': '0512', 'adcode': '320500', 'num': '79', 'name': '苏州市'},\n",
       "   {'citycode': '0760', 'adcode': '442000', 'num': '78', 'name': '中山市'},\n",
       "   {'citycode': '0871', 'adcode': '530100', 'num': '77', 'name': '昆明市'},\n",
       "   {'citycode': '0759', 'adcode': '440800', 'num': '77', 'name': '湛江市'},\n",
       "   {'citycode': '0663', 'adcode': '445200', 'num': '72', 'name': '揭阳市'},\n",
       "   {'citycode': '0591', 'adcode': '350100', 'num': '67', 'name': '福州市'},\n",
       "   {'citycode': '0451', 'adcode': '230100', 'num': '62', 'name': '哈尔滨市'},\n",
       "   {'citycode': '0519', 'adcode': '320400', 'num': '60', 'name': '常州市'},\n",
       "   {'citycode': '024', 'adcode': '210100', 'num': '60', 'name': '沈阳市'},\n",
       "   {'citycode': '0898', 'adcode': '460100', 'num': '59', 'name': '海口市'},\n",
       "   {'citycode': '0771', 'adcode': '450100', 'num': '58', 'name': '南宁市'},\n",
       "   {'citycode': '0596', 'adcode': '350600', 'num': '56', 'name': '漳州市'},\n",
       "   {'citycode': '0668', 'adcode': '440900', 'num': '53', 'name': '茂名市'},\n",
       "   {'citycode': '0510', 'adcode': '320200', 'num': '53', 'name': '无锡市'},\n",
       "   {'citycode': '1852', 'adcode': '810000', 'num': '52', 'name': '香港特别行政区'},\n",
       "   {'citycode': '0756', 'adcode': '440400', 'num': '52', 'name': '珠海市'},\n",
       "   {'citycode': '0531', 'adcode': '370100', 'num': '50', 'name': '济南市'},\n",
       "   {'citycode': '0574', 'adcode': '330200', 'num': '46', 'name': '宁波市'},\n",
       "   {'citycode': '0768', 'adcode': '445100', 'num': '45', 'name': '潮州市'},\n",
       "   {'citycode': '0551', 'adcode': '340100', 'num': '45', 'name': '合肥市'},\n",
       "   {'citycode': '0537', 'adcode': '370800', 'num': '45', 'name': '济宁市'},\n",
       "   {'citycode': '0371', 'adcode': '410100', 'num': '44', 'name': '郑州市'},\n",
       "   {'citycode': '0536', 'adcode': '370700', 'num': '42', 'name': '潍坊市'},\n",
       "   {'citycode': '0758', 'adcode': '441200', 'num': '41', 'name': '肇庆市'},\n",
       "   {'citycode': '0851', 'adcode': '520100', 'num': '39', 'name': '贵阳市'},\n",
       "   {'citycode': '1886', 'adcode': '710000', 'num': '37', 'name': '台湾省'},\n",
       "   {'citycode': '0411', 'adcode': '210200', 'num': '37', 'name': '大连市'},\n",
       "   {'citycode': '0351', 'adcode': '140100', 'num': '36', 'name': '太原市'},\n",
       "   {'citycode': '0797', 'adcode': '360700', 'num': '35', 'name': '赣州市'},\n",
       "   {'citycode': '0594', 'adcode': '350300', 'num': '35', 'name': '莆田市'},\n",
       "   {'citycode': '0763', 'adcode': '441800', 'num': '33', 'name': '清远市'},\n",
       "   {'citycode': '0535', 'adcode': '370600', 'num': '33', 'name': '烟台市'},\n",
       "   {'citycode': '0816', 'adcode': '510700', 'num': '31', 'name': '绵阳市'},\n",
       "   {'citycode': '0311', 'adcode': '130100', 'num': '31', 'name': '石家庄市'},\n",
       "   {'citycode': '0899', 'adcode': '460200', 'num': '30', 'name': '三亚市'},\n",
       "   {'citycode': '0872', 'adcode': '532900', 'num': '30', 'name': '大理白族自治州'},\n",
       "   {'citycode': '0791', 'adcode': '360100', 'num': '30', 'name': '南昌市'},\n",
       "   {'citycode': '0833', 'adcode': '511100', 'num': '28', 'name': '乐山市'},\n",
       "   {'citycode': '0431', 'adcode': '220100', 'num': '28', 'name': '长春市'},\n",
       "   {'citycode': '0376', 'adcode': '411500', 'num': '27', 'name': '信阳市'},\n",
       "   {'citycode': '0662', 'adcode': '441700', 'num': '26', 'name': '阳江市'},\n",
       "   {'citycode': '0579', 'adcode': '330700', 'num': '26', 'name': '金华市'},\n",
       "   {'citycode': '0577', 'adcode': '330300', 'num': '26', 'name': '温州市'},\n",
       "   {'citycode': '0891', 'adcode': '540100', 'num': '25', 'name': '拉萨市'},\n",
       "   {'citycode': '0775', 'adcode': '450900', 'num': '25', 'name': '玉林市'},\n",
       "   {'citycode': '0753', 'adcode': '441400', 'num': '25', 'name': '梅州市'},\n",
       "   {'citycode': '0852', 'adcode': '520300', 'num': '24', 'name': '遵义市'},\n",
       "   {'citycode': '0777', 'adcode': '450700', 'num': '24', 'name': '钦州市'},\n",
       "   {'citycode': '0734', 'adcode': '430400', 'num': '24', 'name': '衡阳市'},\n",
       "   {'citycode': '0660', 'adcode': '441500', 'num': '24', 'name': '汕尾市'},\n",
       "   {'citycode': '1755', 'adcode': '450800', 'num': '23', 'name': '贵港市'},\n",
       "   {'citycode': '0838', 'adcode': '510600', 'num': '23', 'name': '德阳市'},\n",
       "   {'citycode': '0733', 'adcode': '430200', 'num': '23', 'name': '株洲市'},\n",
       "   {'citycode': '0516', 'adcode': '320300', 'num': '23', 'name': '徐州市'},\n",
       "   {'citycode': '0931', 'adcode': '620100', 'num': '22', 'name': '兰州市'},\n",
       "   {'citycode': '0576', 'adcode': '331000', 'num': '22', 'name': '台州市'},\n",
       "   {'citycode': '0533', 'adcode': '370300', 'num': '22', 'name': '淄博市'},\n",
       "   {'citycode': '0310', 'adcode': '130400', 'num': '22', 'name': '邯郸市'},\n",
       "   {'citycode': '0991', 'adcode': '650100', 'num': '21', 'name': '乌鲁木齐市'},\n",
       "   {'citycode': '0818', 'adcode': '511700', 'num': '21', 'name': '达州市'},\n",
       "   {'citycode': '0817', 'adcode': '511300', 'num': '21', 'name': '南充市'},\n",
       "   {'citycode': '0773', 'adcode': '450300', 'num': '21', 'name': '桂林市'},\n",
       "   {'citycode': '0513', 'adcode': '320600', 'num': '21', 'name': '南通市'},\n",
       "   {'citycode': '0774', 'adcode': '450400', 'num': '20', 'name': '梧州市'},\n",
       "   {'citycode': '0573', 'adcode': '330400', 'num': '20', 'name': '嘉兴市'},\n",
       "   {'citycode': '0523', 'adcode': '321200', 'num': '20', 'name': '泰州市'},\n",
       "   {'citycode': '0514', 'adcode': '321000', 'num': '20', 'name': '扬州市'},\n",
       "   {'citycode': '0370', 'adcode': '411400', 'num': '20', 'name': '商丘市'},\n",
       "   {'citycode': '0736', 'adcode': '430700', 'num': '19', 'name': '常德市'},\n",
       "   {'citycode': '0599', 'adcode': '350700', 'num': '19', 'name': '南平市'},\n",
       "   {'citycode': '0539', 'adcode': '371300', 'num': '19', 'name': '临沂市'},\n",
       "   {'citycode': '0515', 'adcode': '320900', 'num': '19', 'name': '盐城市'},\n",
       "   {'citycode': '0511', 'adcode': '321100', 'num': '19', 'name': '镇江市'},\n",
       "   {'citycode': '0335', 'adcode': '130300', 'num': '19', 'name': '秦皇岛市'},\n",
       "   {'citycode': '0317', 'adcode': '130900', 'num': '19', 'name': '沧州市'},\n",
       "   {'citycode': '0316', 'adcode': '131000', 'num': '19', 'name': '廊坊市'},\n",
       "   {'citycode': '0315', 'adcode': '130200', 'num': '19', 'name': '唐山市'},\n",
       "   {'citycode': '1558', 'adcode': '341200', 'num': '18', 'name': '阜阳市'},\n",
       "   {'citycode': '0857', 'adcode': '520500', 'num': '18', 'name': '毕节市'},\n",
       "   {'citycode': '0534', 'adcode': '371400', 'num': '18', 'name': '德州市'},\n",
       "   {'citycode': '0432', 'adcode': '220200', 'num': '18', 'name': '吉林市'},\n",
       "   {'citycode': '0951', 'adcode': '640100', 'num': '17', 'name': '银川市'},\n",
       "   {'citycode': '0746', 'adcode': '431100', 'num': '17', 'name': '永州市'},\n",
       "   {'citycode': '0735', 'adcode': '431000', 'num': '17', 'name': '郴州市'},\n",
       "   {'citycode': '0732', 'adcode': '430300', 'num': '17', 'name': '湘潭市'},\n",
       "   {'citycode': '0691', 'adcode': '532800', 'num': '17', 'name': '西双版纳傣族自治州'},\n",
       "   {'citycode': '0632', 'adcode': '370400', 'num': '17', 'name': '枣庄市'},\n",
       "   {'citycode': '0575', 'adcode': '330600', 'num': '17', 'name': '绍兴市'},\n",
       "   {'citycode': '0471', 'adcode': '150100', 'num': '17', 'name': '呼和浩特市'},\n",
       "   {'citycode': '0359', 'adcode': '140800', 'num': '17', 'name': '运城市'},\n",
       "   {'citycode': '0831', 'adcode': '511500', 'num': '16', 'name': '宜宾市'},\n",
       "   {'citycode': '0772', 'adcode': '450200', 'num': '16', 'name': '柳州市'},\n",
       "   {'citycode': '0739', 'adcode': '430500', 'num': '16', 'name': '邵阳市'},\n",
       "   {'citycode': '0550', 'adcode': '341100', 'num': '16', 'name': '滁州市'},\n",
       "   {'citycode': '0543', 'adcode': '371600', 'num': '16', 'name': '滨州市'},\n",
       "   {'citycode': '0538', 'adcode': '370900', 'num': '16', 'name': '泰安市'},\n",
       "   {'citycode': '0517', 'adcode': '320800', 'num': '16', 'name': '淮安市'},\n",
       "   {'citycode': '0751', 'adcode': '440200', 'num': '15', 'name': '韶关市'},\n",
       "   {'citycode': '0737', 'adcode': '430900', 'num': '15', 'name': '益阳市'},\n",
       "   {'citycode': '1893', 'adcode': '469005', 'num': '14', 'name': '文昌市'},\n",
       "   {'citycode': '0971', 'adcode': '630100', 'num': '14', 'name': '西宁市'},\n",
       "   {'citycode': '0631', 'adcode': '371000', 'num': '14', 'name': '威海市'},\n",
       "   {'citycode': '0597', 'adcode': '350800', 'num': '14', 'name': '龙岩市'},\n",
       "   {'citycode': '0593', 'adcode': '350900', 'num': '14', 'name': '宁德市'},\n",
       "   {'citycode': '0572', 'adcode': '330500', 'num': '14', 'name': '湖州市'},\n",
       "   {'citycode': '0558', 'adcode': '341600', 'num': '14', 'name': '亳州市'},\n",
       "   {'citycode': '0553', 'adcode': '340200', 'num': '14', 'name': '芜湖市'},\n",
       "   {'citycode': '0472', 'adcode': '150200', 'num': '14', 'name': '包头市'},\n",
       "   {'citycode': '0393', 'adcode': '410900', 'num': '14', 'name': '濮阳市'},\n",
       "   {'citycode': '1833', 'adcode': '511400', 'num': '13', 'name': '眉山市'},\n",
       "   {'citycode': '0873', 'adcode': '532500', 'num': '13', 'name': '红河哈尼族彝族自治州'},\n",
       "   {'citycode': '0830', 'adcode': '510500', 'num': '13', 'name': '泸州市'},\n",
       "   {'citycode': '0813', 'adcode': '510300', 'num': '13', 'name': '自贡市'},\n",
       "   {'citycode': '0795', 'adcode': '360900', 'num': '13', 'name': '宜春市'},\n",
       "   {'citycode': '0792', 'adcode': '360400', 'num': '13', 'name': '九江市'},\n",
       "   {'citycode': '0730', 'adcode': '430600', 'num': '13', 'name': '岳阳市'},\n",
       "   {'citycode': '0635', 'adcode': '371500', 'num': '13', 'name': '聊城市'},\n",
       "   {'citycode': '0476', 'adcode': '150400', 'num': '13', 'name': '赤峰市'},\n",
       "   {'citycode': '1832', 'adcode': '511000', 'num': '12', 'name': '内江市'},\n",
       "   {'citycode': '1774', 'adcode': '451100', 'num': '12', 'name': '贺州市'},\n",
       "   {'citycode': '0766', 'adcode': '445300', 'num': '12', 'name': '云浮市'},\n",
       "   {'citycode': '0598', 'adcode': '350400', 'num': '12', 'name': '三明市'},\n",
       "   {'citycode': '0312', 'adcode': '130600', 'num': '12', 'name': '保定市'},\n",
       "   {'citycode': '0874', 'adcode': '530300', 'num': '11', 'name': '曲靖市'},\n",
       "   {'citycode': '0826', 'adcode': '511600', 'num': '11', 'name': '广安市'},\n",
       "   {'citycode': '0554', 'adcode': '340400', 'num': '11', 'name': '淮南市'},\n",
       "   {'citycode': '0530', 'adcode': '371700', 'num': '11', 'name': '菏泽市'},\n",
       "   {'citycode': '0518', 'adcode': '320700', 'num': '11', 'name': '连云港市'},\n",
       "   {'citycode': '0372', 'adcode': '410500', 'num': '11', 'name': '安阳市'},\n",
       "   {'citycode': '1772', 'adcode': '451300', 'num': '10', 'name': '来宾市'},\n",
       "   {'citycode': '1771', 'adcode': '451400', 'num': '10', 'name': '崇左市'},\n",
       "   {'citycode': '0916', 'adcode': '610700', 'num': '10', 'name': '汉中市'},\n",
       "   {'citycode': '0912', 'adcode': '610800', 'num': '10', 'name': '榆林市'},\n",
       "   {'citycode': '0776', 'adcode': '451000', 'num': '10', 'name': '百色市'},\n",
       "   {'citycode': '0477', 'adcode': '150600', 'num': '10', 'name': '鄂尔多斯市'},\n",
       "   {'citycode': '0373', 'adcode': '410700', 'num': '10', 'name': '新乡市'},\n",
       "   {'citycode': '0352', 'adcode': '140200', 'num': '10', 'name': '大同市'},\n",
       "   {'citycode': '0883', 'adcode': '530900', 'num': '9', 'name': '临沧市'},\n",
       "   {'citycode': '0879', 'adcode': '530800', 'num': '9', 'name': '普洱市'},\n",
       "   {'citycode': '0870', 'adcode': '530600', 'num': '9', 'name': '昭通市'},\n",
       "   {'citycode': '0809', 'adcode': '469028', 'num': '9', 'name': '陵水黎族自治县'},\n",
       "   {'citycode': '0716', 'adcode': '421000', 'num': '9', 'name': '荆州市'},\n",
       "   {'citycode': '0564', 'adcode': '341500', 'num': '9', 'name': '六安市'},\n",
       "   {'citycode': '0557', 'adcode': '341300', 'num': '9', 'name': '宿州市'},\n",
       "   {'citycode': '0527', 'adcode': '321300', 'num': '9', 'name': '宿迁市'},\n",
       "   {'citycode': '0454', 'adcode': '230800', 'num': '9', 'name': '佳木斯市'},\n",
       "   {'citycode': '0394', 'adcode': '411600', 'num': '9', 'name': '周口市'},\n",
       "   {'citycode': '1894', 'adcode': '469002', 'num': '8', 'name': '琼海市'},\n",
       "   {'citycode': '0936', 'adcode': '620700', 'num': '8', 'name': '张掖市'},\n",
       "   {'citycode': '0910', 'adcode': '610400', 'num': '8', 'name': '咸阳市'},\n",
       "   {'citycode': '0793', 'adcode': '361100', 'num': '8', 'name': '上饶市'},\n",
       "   {'citycode': '0762', 'adcode': '441600', 'num': '8', 'name': '河源市'},\n",
       "   {'citycode': '0429', 'adcode': '211400', 'num': '8', 'name': '葫芦岛市'},\n",
       "   {'citycode': '0418', 'adcode': '210900', 'num': '8', 'name': '阜新市'},\n",
       "   {'citycode': '0416', 'adcode': '210700', 'num': '8', 'name': '锦州市'},\n",
       "   {'citycode': '0412', 'adcode': '210300', 'num': '8', 'name': '鞍山市'},\n",
       "   {'citycode': '0398', 'adcode': '411200', 'num': '8', 'name': '三门峡市'},\n",
       "   {'citycode': '0377', 'adcode': '411300', 'num': '8', 'name': '南阳市'},\n",
       "   {'citycode': '0354', 'adcode': '140700', 'num': '8', 'name': '晋中市'},\n",
       "   {'citycode': '1935', 'adcode': '620600', 'num': '7', 'name': '武威市'},\n",
       "   {'citycode': '1433', 'adcode': '222400', 'num': '7', 'name': '延边朝鲜族自治州'},\n",
       "   {'citycode': '0859', 'adcode': '522300', 'num': '7', 'name': '黔西南布依族苗族自治州'},\n",
       "   {'citycode': '0856', 'adcode': '520600', 'num': '7', 'name': '铜仁市'},\n",
       "   {'citycode': '0738', 'adcode': '431300', 'num': '7', 'name': '娄底市'},\n",
       "   {'citycode': '0633', 'adcode': '371100', 'num': '7', 'name': '日照市'},\n",
       "   {'citycode': '0563', 'adcode': '341800', 'num': '7', 'name': '宣城市'},\n",
       "   {'citycode': '0546', 'adcode': '370500', 'num': '7', 'name': '东营市'},\n",
       "   {'citycode': '0998', 'adcode': '653100', 'num': '6', 'name': '喀什地区'},\n",
       "   {'citycode': '0837', 'adcode': '513200', 'num': '6', 'name': '阿坝藏族羌族自治州'},\n",
       "   {'citycode': '0805', 'adcode': '460400', 'num': '6', 'name': '儋州市'},\n",
       "   {'citycode': '0745', 'adcode': '431200', 'num': '6', 'name': '怀化市'},\n",
       "   {'citycode': '0717', 'adcode': '420500', 'num': '6', 'name': '宜昌市'},\n",
       "   {'citycode': '0562', 'adcode': '340700', 'num': '6', 'name': '铜陵市'},\n",
       "   {'citycode': '0455', 'adcode': '231200', 'num': '6', 'name': '绥化市'},\n",
       "   {'citycode': '0419', 'adcode': '211000', 'num': '6', 'name': '辽阳市'},\n",
       "   {'citycode': '0417', 'adcode': '210800', 'num': '6', 'name': '营口市'},\n",
       "   {'citycode': '0379', 'adcode': '410300', 'num': '6', 'name': '洛阳市'},\n",
       "   {'citycode': '0318', 'adcode': '131100', 'num': '6', 'name': '衡水市'},\n",
       "   {'citycode': '0938', 'adcode': '620500', 'num': '5', 'name': '天水市'},\n",
       "   {'citycode': '0858', 'adcode': '520200', 'num': '5', 'name': '六盘水市'},\n",
       "   {'citycode': '0839', 'adcode': '510800', 'num': '5', 'name': '广元市'},\n",
       "   {'citycode': '0778', 'adcode': '451200', 'num': '5', 'name': '河池市'},\n",
       "   {'citycode': '0718', 'adcode': '422800', 'num': '5', 'name': '恩施土家族苗族自治州'},\n",
       "   {'citycode': '0713', 'adcode': '421100', 'num': '5', 'name': '黄冈市'},\n",
       "   {'citycode': '0437', 'adcode': '220400', 'num': '5', 'name': '辽源市'},\n",
       "   {'citycode': '0358', 'adcode': '141100', 'num': '5', 'name': '吕梁市'},\n",
       "   {'citycode': '0350', 'adcode': '140900', 'num': '5', 'name': '忻州市'},\n",
       "   {'citycode': '0314', 'adcode': '130800', 'num': '5', 'name': '承德市'},\n",
       "   {'citycode': '1898', 'adcode': '469006', 'num': '4', 'name': '万宁市'},\n",
       "   {'citycode': '0953', 'adcode': '640300', 'num': '4', 'name': '吴忠市'},\n",
       "   {'citycode': '0943', 'adcode': '620400', 'num': '4', 'name': '白银市'},\n",
       "   {'citycode': '0915', 'adcode': '610900', 'num': '4', 'name': '安康市'},\n",
       "   {'citycode': '0877', 'adcode': '530400', 'num': '4', 'name': '玉溪市'},\n",
       "   {'citycode': '0875', 'adcode': '530500', 'num': '4', 'name': '保山市'},\n",
       "   {'citycode': '0825', 'adcode': '510900', 'num': '4', 'name': '遂宁市'},\n",
       "   {'citycode': '0812', 'adcode': '510400', 'num': '4', 'name': '攀枝花市'},\n",
       "   {'citycode': '0798', 'adcode': '360200', 'num': '4', 'name': '景德镇市'},\n",
       "   {'citycode': '0796', 'adcode': '360800', 'num': '4', 'name': '吉安市'},\n",
       "   {'citycode': '0794', 'adcode': '361000', 'num': '4', 'name': '抚州市'},\n",
       "   {'citycode': '0779', 'adcode': '450500', 'num': '4', 'name': '北海市'},\n",
       "   {'citycode': '0770', 'adcode': '450600', 'num': '4', 'name': '防城港市'},\n",
       "   {'citycode': '0719', 'adcode': '420300', 'num': '4', 'name': '十堰市'},\n",
       "   {'citycode': '0712', 'adcode': '420900', 'num': '4', 'name': '孝感市'},\n",
       "   {'citycode': '0710', 'adcode': '420600', 'num': '4', 'name': '襄阳市'},\n",
       "   {'citycode': '0578', 'adcode': '331100', 'num': '4', 'name': '丽水市'},\n",
       "   {'citycode': '0566', 'adcode': '341700', 'num': '4', 'name': '池州市'},\n",
       "   {'citycode': '0478', 'adcode': '150800', 'num': '4', 'name': '巴彦淖尔市'},\n",
       "   {'citycode': '0473', 'adcode': '150300', 'num': '4', 'name': '乌海市'},\n",
       "   {'citycode': '0458', 'adcode': '230700', 'num': '4', 'name': '伊春市'},\n",
       "   {'citycode': '0421', 'adcode': '211300', 'num': '4', 'name': '朝阳市'},\n",
       "   {'citycode': '0414', 'adcode': '210500', 'num': '4', 'name': '本溪市'},\n",
       "   {'citycode': '0410', 'adcode': '211200', 'num': '4', 'name': '铁岭市'},\n",
       "   {'citycode': '0396', 'adcode': '411700', 'num': '4', 'name': '驻马店市'},\n",
       "   {'citycode': '0349', 'adcode': '140600', 'num': '4', 'name': '朔州市'},\n",
       "   {'citycode': '2728', 'adcode': '429005', 'num': '3', 'name': '潜江市'},\n",
       "   {'citycode': '1728', 'adcode': '429006', 'num': '3', 'name': '天门市'},\n",
       "   {'citycode': '1391', 'adcode': '419001', 'num': '3', 'name': '济源市'},\n",
       "   {'citycode': '0996', 'adcode': '652800', 'num': '3', 'name': '巴音郭楞蒙古自治州'},\n",
       "   {'citycode': '0990', 'adcode': '650200', 'num': '3', 'name': '克拉玛依市'},\n",
       "   {'citycode': '0937', 'adcode': '620900', 'num': '3', 'name': '酒泉市'},\n",
       "   {'citycode': '0935', 'adcode': '620300', 'num': '3', 'name': '金昌市'},\n",
       "   {'citycode': '0917', 'adcode': '610300', 'num': '3', 'name': '宝鸡市'},\n",
       "   {'citycode': '0888', 'adcode': '530700', 'num': '3', 'name': '丽江市'},\n",
       "   {'citycode': '0855', 'adcode': '522600', 'num': '3', 'name': '黔东南苗族侗族自治州'},\n",
       "   {'citycode': '0853', 'adcode': '520400', 'num': '3', 'name': '安顺市'},\n",
       "   {'citycode': '0834', 'adcode': '513400', 'num': '3', 'name': '凉山彝族自治州'},\n",
       "   {'citycode': '0832', 'adcode': '512000', 'num': '3', 'name': '资阳市'},\n",
       "   {'citycode': '0807', 'adcode': '469007', 'num': '3', 'name': '东方市'},\n",
       "   {'citycode': '0804', 'adcode': '469023', 'num': '3', 'name': '澄迈县'},\n",
       "   {'citycode': '0803', 'adcode': '469026', 'num': '3', 'name': '昌江黎族自治县'},\n",
       "   {'citycode': '0555', 'adcode': '340500', 'num': '3', 'name': '马鞍山市'},\n",
       "   {'citycode': '0482', 'adcode': '152200', 'num': '3', 'name': '兴安盟'},\n",
       "   {'citycode': '0479', 'adcode': '152500', 'num': '3', 'name': '锡林郭勒盟'},\n",
       "   {'citycode': '0459', 'adcode': '230600', 'num': '3', 'name': '大庆市'},\n",
       "   {'citycode': '0438', 'adcode': '220700', 'num': '3', 'name': '松原市'},\n",
       "   {'citycode': '0427', 'adcode': '211100', 'num': '3', 'name': '盘锦市'},\n",
       "   {'citycode': '0375', 'adcode': '410400', 'num': '3', 'name': '平顶山市'},\n",
       "   {'citycode': '0357', 'adcode': '141000', 'num': '3', 'name': '临汾市'},\n",
       "   {'citycode': '0355', 'adcode': '140400', 'num': '3', 'name': '长治市'},\n",
       "   {'citycode': '0319', 'adcode': '130500', 'num': '3', 'name': '邢台市'},\n",
       "   {'citycode': '1994', 'adcode': '659004', 'num': '2', 'name': '五家渠市'},\n",
       "   {'citycode': '1953', 'adcode': '640500', 'num': '2', 'name': '中卫市'},\n",
       "   {'citycode': '1937', 'adcode': '620200', 'num': '2', 'name': '嘉峪关市'},\n",
       "   {'citycode': '1896', 'adcode': '469024', 'num': '2', 'name': '临高县'},\n",
       "   {'citycode': '0999', 'adcode': '654000', 'num': '2', 'name': '伊犁哈萨克自治州'},\n",
       "   {'citycode': '0994', 'adcode': '652300', 'num': '2', 'name': '昌吉回族自治州'},\n",
       "   {'citycode': '0913', 'adcode': '610500', 'num': '2', 'name': '渭南市'},\n",
       "   {'citycode': '0894', 'adcode': '540400', 'num': '2', 'name': '林芝市'},\n",
       "   {'citycode': '0887', 'adcode': '533400', 'num': '2', 'name': '迪庆藏族自治州'},\n",
       "   {'citycode': '0878', 'adcode': '532300', 'num': '2', 'name': '楚雄彝族自治州'},\n",
       "   {'citycode': '0876', 'adcode': '532600', 'num': '2', 'name': '文山壮族苗族自治州'},\n",
       "   {'citycode': '0854', 'adcode': '522700', 'num': '2', 'name': '黔南布依族苗族自治州'},\n",
       "   {'citycode': '0835', 'adcode': '511800', 'num': '2', 'name': '雅安市'},\n",
       "   {'citycode': '0827', 'adcode': '511900', 'num': '2', 'name': '巴中市'},\n",
       "   {'citycode': '0799', 'adcode': '360300', 'num': '2', 'name': '萍乡市'},\n",
       "   {'citycode': '0790', 'adcode': '360500', 'num': '2', 'name': '新余市'},\n",
       "   {'citycode': '0728', 'adcode': '429004', 'num': '2', 'name': '仙桃市'},\n",
       "   {'citycode': '0724', 'adcode': '420800', 'num': '2', 'name': '荆门市'},\n",
       "   {'citycode': '0715', 'adcode': '421200', 'num': '2', 'name': '咸宁市'},\n",
       "   {'citycode': '0714', 'adcode': '420200', 'num': '2', 'name': '黄石市'},\n",
       "   {'citycode': '0692', 'adcode': '533100', 'num': '2', 'name': '德宏傣族景颇族自治州'},\n",
       "   {'citycode': '0561', 'adcode': '340600', 'num': '2', 'name': '淮北市'},\n",
       "   {'citycode': '0475', 'adcode': '150500', 'num': '2', 'name': '通辽市'},\n",
       "   {'citycode': '0470', 'adcode': '150700', 'num': '2', 'name': '呼伦贝尔市'},\n",
       "   {'citycode': '0453', 'adcode': '231000', 'num': '2', 'name': '牡丹江市'},\n",
       "   {'citycode': '0452', 'adcode': '230200', 'num': '2', 'name': '齐齐哈尔市'},\n",
       "   {'citycode': '0434', 'adcode': '220300', 'num': '2', 'name': '四平市'},\n",
       "   {'citycode': '0413', 'adcode': '210400', 'num': '2', 'name': '抚顺市'},\n",
       "   {'citycode': '0391', 'adcode': '410800', 'num': '2', 'name': '焦作市'},\n",
       "   {'citycode': '0374', 'adcode': '411000', 'num': '2', 'name': '许昌市'},\n",
       "   {'citycode': '0356', 'adcode': '140500', 'num': '2', 'name': '晋城市'},\n",
       "   {'citycode': '0353', 'adcode': '140300', 'num': '2', 'name': '阳泉市'},\n",
       "   {'citycode': '0313', 'adcode': '130700', 'num': '2', 'name': '张家口市'}]},\n",
       " 'count': '0',\n",
       " 'infocode': '10000',\n",
       " 'pois': [],\n",
       " 'status': '1',\n",
       " 'info': 'OK'}"
      ]
     },
     "execution_count": 13,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "r.json()"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "535a195b",
   "metadata": {},
   "source": [
    "## 2、基于周边搜索"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "id": "ba05f9a6",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "'113.678280,23.628439'"
      ]
     },
     "execution_count": 14,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import requests\n",
    "geo_url = \"https://restapi.amap.com/v3/geocode/geo?parameters\"\n",
    "payload = {\n",
    "    \"key\":\"f7b3c94b56fe002e2b98f6bb8d8a5f46\",\n",
    "    \"address\":\"广东省广州市从化区广州南方学院\"\n",
    "}\n",
    "r = requests.get(url=geo_url, params=payload)\n",
    "广州南方学院_location = r.json()['geocodes'][0]['location']\n",
    "广州南方学院_location"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "id": "1dfb9328",
   "metadata": {},
   "outputs": [],
   "source": [
    "around_url = 'https://restapi.amap.com/v3/place/around?parameters'\n",
    "\n",
    "payload = {\n",
    "    \"key\":\"f7b3c94b56fe002e2b98f6bb8d8a5f46\",\n",
    "    \"location\":广州南方学院_location,\n",
    "    \"keywords\":\"篮球场\"\n",
    "}\n",
    "r = requests.get(around_url,params=payload)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "id": "bcc3868c",
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'suggestion': {'keywords': [], 'cities': []},\n",
       " 'count': '96',\n",
       " 'infocode': '10000',\n",
       " 'pois': [{'parent': [],\n",
       "   'address': '博学路20号',\n",
       "   'distance': '142',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': []},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '广州南方学院-西区篮球场',\n",
       "   'location': '113.677851,23.629654',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0H1XKYTYG'},\n",
       "  {'parent': [],\n",
       "   'address': '博学路2号',\n",
       "   'distance': '615',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': []},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '广州南方学院-西区大篮球场',\n",
       "   'location': '113.676146,23.633610',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0HRVOFC24'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇云星大道流溪河畔华辉度假村',\n",
       "   'distance': '4558',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '4.0'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '华辉度假村-篮球馆',\n",
       "   'location': '113.634306,23.621128',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B00141SY2P'},\n",
       "  {'parent': [],\n",
       "   'address': '麻村西井新村十巷十四号',\n",
       "   'distance': '6989',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '3.7'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;体育休闲服务场所;体育休闲服务场所',\n",
       "   'photos': [],\n",
       "   'typecode': '080000',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '从化麻一村蓝球场',\n",
       "   'location': '113.613966,23.606772',\n",
       "   'tel': '13609053811',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFHDSVYX'},\n",
       "  {'parent': [],\n",
       "   'address': '御泉大道与马会大街交叉口西300米',\n",
       "   'distance': '7986',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '4.3'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '滴翠山庄-篮球场',\n",
       "   'location': '113.709579,23.694209',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFGBJL7Z'},\n",
       "  {'parent': [],\n",
       "   'address': 'G105(京珠线)',\n",
       "   'distance': '8563',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': []},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '虫湾自菽水碧温泉度假村-篮球场',\n",
       "   'location': '113.714658,23.697773',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0HKLSPFIL'},\n",
       "  {'parent': [],\n",
       "   'address': '绿道永盛花园南侧约60米',\n",
       "   'distance': '11454',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '3.4'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '广州市流溪河碧道-篮球场',\n",
       "   'location': '113.603998,23.551285',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0HK09FJU4'},\n",
       "  {'parent': [],\n",
       "   'address': '城郊街新星村大夫围',\n",
       "   'distance': '11624',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '3.8'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;体育休闲服务场所;体育休闲服务场所',\n",
       "   'photos': [],\n",
       "   'typecode': '080000',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '大夫围篮球场',\n",
       "   'location': '113.568239,23.601258',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0GRCUDOG2'},\n",
       "  {'parent': [],\n",
       "   'address': '城郊街河滨北路向阳村十壮大车87号',\n",
       "   'distance': '11644',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '3.7'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/58c53b0fbccc63cfa2b85cc544757c66'}],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '东风530篮球俱乐部',\n",
       "   'location': '113.599433,23.552791',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0HGYDWCTV'},\n",
       "  {'parent': [],\n",
       "   'address': '郊街新村北路',\n",
       "   'distance': '12273',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '3.4'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;运动场所',\n",
       "   'photos': [],\n",
       "   'typecode': '080100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '篮球广场',\n",
       "   'location': '113.586581,23.557058',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFL1ERXT'},\n",
       "  {'parent': [],\n",
       "   'address': '西街市场',\n",
       "   'distance': '12581',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '3.7'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;体育休闲服务场所;体育休闲服务场所',\n",
       "   'photos': [],\n",
       "   'typecode': '080000',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '田边村球场',\n",
       "   'location': '113.588417,23.551027',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFIVT1AD'},\n",
       "  {'parent': [],\n",
       "   'address': '河东南路1-7号附近',\n",
       "   'distance': '12639',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '4.5'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/8104df48263d05da42ae14eef6881689'}],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '华蒙星少儿篮球俱乐部(街口店)',\n",
       "   'location': '113.595492,23.543939',\n",
       "   'tel': '020-87966066',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFL0DDYS'},\n",
       "  {'parent': [],\n",
       "   'address': '萃安里58号',\n",
       "   'distance': '13255',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '4.2'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://aos-cdn-image.amap.com/sns/ugccomment/7e7d4deb-c78b-4a1e-96cf-51c24a53926e.jpg'},\n",
       "    {'title': [],\n",
       "     'url': 'http://aos-cdn-image.amap.com/sns/ugccomment/d4407b0c-4932-4bfa-b01f-74e6ea844747.jpg'},\n",
       "    {'title': [],\n",
       "     'url': 'http://aos-cdn-image.amap.com/sns/ugccomment/75bb1cfd-ea69-4529-9a59-ff1d5e711469.jpg'}],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '广州星跃篮球训练馆',\n",
       "   'location': '113.581199,23.549290',\n",
       "   'tel': '18620199644',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFKL6J9B'},\n",
       "  {'parent': [],\n",
       "   'address': '河东南路272号',\n",
       "   'distance': '13355',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '4.3'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;运动场所',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/efe1e46ca58ff1a360c9af1e0f9b5994'}],\n",
       "   'typecode': '080100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '健乐球馆',\n",
       "   'location': '113.599421,23.532675',\n",
       "   'tel': '020-87982828',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFI1TFV5'},\n",
       "  {'parent': [],\n",
       "   'address': '环市东路166号广州城建职业学院内',\n",
       "   'distance': '13397',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '3.4'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '篮球场',\n",
       "   'location': '113.612905,23.524059',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFGBHSY7'},\n",
       "  {'parent': [],\n",
       "   'address': '绿道德福河畔花园-莱茵水岸东南侧约140米',\n",
       "   'distance': '14156',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '3.8'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;运动场所',\n",
       "   'photos': [],\n",
       "   'typecode': '080100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '林书豪-李群篮球联盟',\n",
       "   'location': '113.598957,23.524103',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0HKH7ET45'},\n",
       "  {'parent': [],\n",
       "   'address': '沿江北路150号附近',\n",
       "   'distance': '15336',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '4.0'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;体育休闲服务场所;体育休闲服务场所',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://aos-cdn-image.amap.com/sns/ugccomment/f70753b9-7482-4834-83eb-d551515ab5a8.jpg'}],\n",
       "   'typecode': '080000',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '坑尾村篮球场',\n",
       "   'location': '113.531138,23.600104',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFKP84WT'},\n",
       "  {'parent': [],\n",
       "   'address': '江埔街南方村',\n",
       "   'distance': '15899',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '3.7'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;体育休闲服务场所;体育休闲服务场所',\n",
       "   'photos': [],\n",
       "   'typecode': '080000',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '南方村篮球场',\n",
       "   'location': '113.579487,23.517988',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0HKOCIL77'},\n",
       "  {'parent': [],\n",
       "   'address': '员村美食街与广从公路交叉口东南420米',\n",
       "   'distance': '16479',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': []},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '华南农业大学珠江学院篮球场',\n",
       "   'location': '113.579948,23.510999',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0HG27ZQU5'},\n",
       "  {'parent': [],\n",
       "   'address': '棋杆高沙街与棋杆沙围一街交叉口东南320米',\n",
       "   'distance': '20865',\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [], 'rating': '3.6'},\n",
       "   'biz_type': [],\n",
       "   'cityname': '广州市',\n",
       "   'type': '体育休闲服务;运动场馆;篮球场馆',\n",
       "   'photos': [],\n",
       "   'typecode': '080104',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '瓦窑篮球场',\n",
       "   'location': '113.477748,23.591445',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0G10ACN4L'}],\n",
       " 'status': '1',\n",
       " 'info': 'OK'}"
      ]
     },
     "execution_count": 16,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "r.json()"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "59fa39d8",
   "metadata": {},
   "source": [
    "## 中餐厅"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "id": "0e8abe2b",
   "metadata": {},
   "outputs": [],
   "source": [
    "# 2. 请求方法：GET\n",
    "# 3. 请求的搜索POI2.0地址：https://restapi.amap.com/v5/place/around?parameters\n",
    "POI2_url = \"https://restapi.amap.com/v5/place/around?parameters\"\n",
    "\n",
    "# 4. 请求的参数（payload）\n",
    "payload = {\n",
    "    \"key\":\"f7b3c94b56fe002e2b98f6bb8d8a5f46\",\n",
    "    \"keywords\":\"中餐厅\",\n",
    "    \"location\":\"113.678280,23.628439\",\n",
    "    \"show_fields\":\"photos,business\"\n",
    "}\n",
    "\n",
    "# 5. 发起请求\n",
    "r = requests.get(url=POI2_url, params=payload)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "id": "8e548890",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<Response [200]>"
      ]
     },
     "execution_count": 18,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "r"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 19,
   "id": "d5bebaf3",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'status': '1',\n",
       " 'info': 'OK',\n",
       " 'infocode': '10000',\n",
       " 'pois': [{'name': '喜洋洋烧烤城',\n",
       "   'id': 'B0FFKT56Q8',\n",
       "   'location': '113.678474,23.628422',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'typecode': '050100',\n",
       "   'pname': '广东省',\n",
       "   'cityname': '广州市',\n",
       "   'adname': '从化区',\n",
       "   'address': '博学路6号(广州南方学院南门口旁)',\n",
       "   'pcode': '440000',\n",
       "   'citycode': '020',\n",
       "   'adcode': '440117',\n",
       "   'business': {'rectag': '烤串', 'keytag': '烤串'}},\n",
       "  {'name': '港式住家饭(中大店)',\n",
       "   'id': 'B0H1M90UGD',\n",
       "   'location': '113.679504,23.628108',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'typecode': '050100',\n",
       "   'pname': '广东省',\n",
       "   'cityname': '广州市',\n",
       "   'adname': '从化区',\n",
       "   'address': '温泉镇中山大学南方学院',\n",
       "   'pcode': '440000',\n",
       "   'citycode': '020',\n",
       "   'adcode': '440117',\n",
       "   'business': {'rectag': '香港菜', 'keytag': '香港菜'}},\n",
       "  {'name': '找餐时间(轻食店)',\n",
       "   'id': 'B0H31YY48Q',\n",
       "   'location': '113.679695,23.628204',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'typecode': '050100',\n",
       "   'pname': '广东省',\n",
       "   'cityname': '广州市',\n",
       "   'adname': '从化区',\n",
       "   'address': '温泉镇中大南方',\n",
       "   'pcode': '440000',\n",
       "   'citycode': '020',\n",
       "   'adcode': '440117',\n",
       "   'business': {'rectag': '中餐', 'keytag': '中餐'}},\n",
       "  {'name': '巴老冒豆花冒菜(中大店)',\n",
       "   'id': 'B0HROCISXU',\n",
       "   'location': '113.679739,23.628221',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'typecode': '050100',\n",
       "   'pname': '广东省',\n",
       "   'cityname': '广州市',\n",
       "   'adname': '从化区',\n",
       "   'address': '温泉镇中大南方',\n",
       "   'pcode': '440000',\n",
       "   'citycode': '020',\n",
       "   'adcode': '440117',\n",
       "   'business': {'rectag': '冒菜', 'keytag': '冒菜'}},\n",
       "  {'name': '牛哥烧烤',\n",
       "   'id': 'B0HROCM3MH',\n",
       "   'location': '113.679809,23.628326',\n",
       "   'type': '餐饮服务;中餐厅;特色/地方风味餐厅',\n",
       "   'typecode': '050118',\n",
       "   'pname': '广东省',\n",
       "   'cityname': '广州市',\n",
       "   'adname': '从化区',\n",
       "   'address': '温泉镇中山大学南方学院',\n",
       "   'pcode': '440000',\n",
       "   'citycode': '020',\n",
       "   'adcode': '440117',\n",
       "   'business': {'rectag': '烤串', 'keytag': '烤串'}},\n",
       "  {'name': '桃缘瓦舍',\n",
       "   'id': 'B0IGC5BQCT',\n",
       "   'location': '113.680297,23.627788',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'typecode': '050100',\n",
       "   'pname': '广东省',\n",
       "   'cityname': '广州市',\n",
       "   'adname': '从化区',\n",
       "   'address': '温泉镇平岗村乌土平岗街29号',\n",
       "   'pcode': '440000',\n",
       "   'citycode': '020',\n",
       "   'adcode': '440117',\n",
       "   'business': {'rectag': '中餐', 'keytag': '中餐', 'rating': '2.6'}},\n",
       "  {'name': '歡喜烤鱼饭',\n",
       "   'id': 'B0HROCIT9Q',\n",
       "   'location': '113.680349,23.627573',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'typecode': '050100',\n",
       "   'pname': '广东省',\n",
       "   'cityname': '广州市',\n",
       "   'adname': '从化区',\n",
       "   'address': '乌土村中南公寓',\n",
       "   'pcode': '440000',\n",
       "   'citycode': '020',\n",
       "   'adcode': '440117',\n",
       "   'business': {'rectag': '烤鱼', 'keytag': '烤鱼'}},\n",
       "  {'name': '99BARBECUE烤吧(中大店)',\n",
       "   'id': 'B0HROCMIX1',\n",
       "   'location': '113.680449,23.629268',\n",
       "   'type': '餐饮服务;中餐厅;特色/地方风味餐厅',\n",
       "   'typecode': '050118',\n",
       "   'pname': '广东省',\n",
       "   'cityname': '广州市',\n",
       "   'adname': '从化区',\n",
       "   'address': '中大南方学院后门',\n",
       "   'pcode': '440000',\n",
       "   'citycode': '020',\n",
       "   'adcode': '440117',\n",
       "   'business': {'rectag': '烧烤', 'keytag': '烧烤', 'rating': '2.7'}},\n",
       "  {'name': '湖边纸包鱼',\n",
       "   'id': 'B0FFL7NUA2',\n",
       "   'location': '113.679861,23.630285',\n",
       "   'type': '餐饮服务;中餐厅;四川菜(川菜)',\n",
       "   'typecode': '050102',\n",
       "   'pname': '广东省',\n",
       "   'cityname': '广州市',\n",
       "   'adname': '从化区',\n",
       "   'address': '广州南方学院',\n",
       "   'pcode': '440000',\n",
       "   'citycode': '020',\n",
       "   'adcode': '440117',\n",
       "   'business': {'tel': '13924024938',\n",
       "    'rectag': '川菜',\n",
       "    'keytag': '川菜',\n",
       "    'rating': '4.5',\n",
       "    'opentime_today': '09:00-23:00',\n",
       "    'opentime_week': '09:00-23:00'},\n",
       "   'photos': [{'title': '',\n",
       "     'url': 'http://store.is.autonavi.com/showpic/20080ba9f6fcd2808d64ce149b517ca9'},\n",
       "    {'title': '',\n",
       "     'url': 'http://store.is.autonavi.com/showpic/9f40694ca108a175d36847d03ecf4ec0'},\n",
       "    {'title': '',\n",
       "     'url': 'https://img.alicdn.com/imgextra/i2/3695320962/O1CN01JFnmLv1IydhNhdLT4_!!3695320962-0-kbcontentapng.jpg'}]},\n",
       "  {'name': '壹休盖饭',\n",
       "   'id': 'B0HRHG0RSP',\n",
       "   'location': '113.679611,23.630517',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'typecode': '050100',\n",
       "   'pname': '广东省',\n",
       "   'cityname': '广州市',\n",
       "   'adname': '从化区',\n",
       "   'address': '温泉镇乌土村上围2队13号',\n",
       "   'pcode': '440000',\n",
       "   'citycode': '020',\n",
       "   'adcode': '440117',\n",
       "   'business': {'rectag': '盖饭', 'keytag': '盖饭'}}],\n",
       " 'count': '10'}"
      ]
     },
     "execution_count": 19,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "r.json()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 20,
   "id": "5126a898",
   "metadata": {},
   "outputs": [],
   "source": [
    "import pandas as pd"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 21,
   "id": "011a1334",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>name</th>\n",
       "      <th>id</th>\n",
       "      <th>location</th>\n",
       "      <th>type</th>\n",
       "      <th>typecode</th>\n",
       "      <th>pname</th>\n",
       "      <th>cityname</th>\n",
       "      <th>adname</th>\n",
       "      <th>address</th>\n",
       "      <th>pcode</th>\n",
       "      <th>citycode</th>\n",
       "      <th>adcode</th>\n",
       "      <th>business.rectag</th>\n",
       "      <th>business.keytag</th>\n",
       "      <th>business.rating</th>\n",
       "      <th>photos</th>\n",
       "      <th>business.tel</th>\n",
       "      <th>business.opentime_today</th>\n",
       "      <th>business.opentime_week</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>喜洋洋烧烤城</td>\n",
       "      <td>B0FFKT56Q8</td>\n",
       "      <td>113.678474,23.628422</td>\n",
       "      <td>餐饮服务;中餐厅;中餐厅</td>\n",
       "      <td>050100</td>\n",
       "      <td>广东省</td>\n",
       "      <td>广州市</td>\n",
       "      <td>从化区</td>\n",
       "      <td>博学路6号(广州南方学院南门口旁)</td>\n",
       "      <td>440000</td>\n",
       "      <td>020</td>\n",
       "      <td>440117</td>\n",
       "      <td>烤串</td>\n",
       "      <td>烤串</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>港式住家饭(中大店)</td>\n",
       "      <td>B0H1M90UGD</td>\n",
       "      <td>113.679504,23.628108</td>\n",
       "      <td>餐饮服务;中餐厅;中餐厅</td>\n",
       "      <td>050100</td>\n",
       "      <td>广东省</td>\n",
       "      <td>广州市</td>\n",
       "      <td>从化区</td>\n",
       "      <td>温泉镇中山大学南方学院</td>\n",
       "      <td>440000</td>\n",
       "      <td>020</td>\n",
       "      <td>440117</td>\n",
       "      <td>香港菜</td>\n",
       "      <td>香港菜</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>找餐时间(轻食店)</td>\n",
       "      <td>B0H31YY48Q</td>\n",
       "      <td>113.679695,23.628204</td>\n",
       "      <td>餐饮服务;中餐厅;中餐厅</td>\n",
       "      <td>050100</td>\n",
       "      <td>广东省</td>\n",
       "      <td>广州市</td>\n",
       "      <td>从化区</td>\n",
       "      <td>温泉镇中大南方</td>\n",
       "      <td>440000</td>\n",
       "      <td>020</td>\n",
       "      <td>440117</td>\n",
       "      <td>中餐</td>\n",
       "      <td>中餐</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>巴老冒豆花冒菜(中大店)</td>\n",
       "      <td>B0HROCISXU</td>\n",
       "      <td>113.679739,23.628221</td>\n",
       "      <td>餐饮服务;中餐厅;中餐厅</td>\n",
       "      <td>050100</td>\n",
       "      <td>广东省</td>\n",
       "      <td>广州市</td>\n",
       "      <td>从化区</td>\n",
       "      <td>温泉镇中大南方</td>\n",
       "      <td>440000</td>\n",
       "      <td>020</td>\n",
       "      <td>440117</td>\n",
       "      <td>冒菜</td>\n",
       "      <td>冒菜</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>牛哥烧烤</td>\n",
       "      <td>B0HROCM3MH</td>\n",
       "      <td>113.679809,23.628326</td>\n",
       "      <td>餐饮服务;中餐厅;特色/地方风味餐厅</td>\n",
       "      <td>050118</td>\n",
       "      <td>广东省</td>\n",
       "      <td>广州市</td>\n",
       "      <td>从化区</td>\n",
       "      <td>温泉镇中山大学南方学院</td>\n",
       "      <td>440000</td>\n",
       "      <td>020</td>\n",
       "      <td>440117</td>\n",
       "      <td>烤串</td>\n",
       "      <td>烤串</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <td>桃缘瓦舍</td>\n",
       "      <td>B0IGC5BQCT</td>\n",
       "      <td>113.680297,23.627788</td>\n",
       "      <td>餐饮服务;中餐厅;中餐厅</td>\n",
       "      <td>050100</td>\n",
       "      <td>广东省</td>\n",
       "      <td>广州市</td>\n",
       "      <td>从化区</td>\n",
       "      <td>温泉镇平岗村乌土平岗街29号</td>\n",
       "      <td>440000</td>\n",
       "      <td>020</td>\n",
       "      <td>440117</td>\n",
       "      <td>中餐</td>\n",
       "      <td>中餐</td>\n",
       "      <td>2.6</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>歡喜烤鱼饭</td>\n",
       "      <td>B0HROCIT9Q</td>\n",
       "      <td>113.680349,23.627573</td>\n",
       "      <td>餐饮服务;中餐厅;中餐厅</td>\n",
       "      <td>050100</td>\n",
       "      <td>广东省</td>\n",
       "      <td>广州市</td>\n",
       "      <td>从化区</td>\n",
       "      <td>乌土村中南公寓</td>\n",
       "      <td>440000</td>\n",
       "      <td>020</td>\n",
       "      <td>440117</td>\n",
       "      <td>烤鱼</td>\n",
       "      <td>烤鱼</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>7</th>\n",
       "      <td>99BARBECUE烤吧(中大店)</td>\n",
       "      <td>B0HROCMIX1</td>\n",
       "      <td>113.680449,23.629268</td>\n",
       "      <td>餐饮服务;中餐厅;特色/地方风味餐厅</td>\n",
       "      <td>050118</td>\n",
       "      <td>广东省</td>\n",
       "      <td>广州市</td>\n",
       "      <td>从化区</td>\n",
       "      <td>中大南方学院后门</td>\n",
       "      <td>440000</td>\n",
       "      <td>020</td>\n",
       "      <td>440117</td>\n",
       "      <td>烧烤</td>\n",
       "      <td>烧烤</td>\n",
       "      <td>2.7</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>湖边纸包鱼</td>\n",
       "      <td>B0FFL7NUA2</td>\n",
       "      <td>113.679861,23.630285</td>\n",
       "      <td>餐饮服务;中餐厅;四川菜(川菜)</td>\n",
       "      <td>050102</td>\n",
       "      <td>广东省</td>\n",
       "      <td>广州市</td>\n",
       "      <td>从化区</td>\n",
       "      <td>广州南方学院</td>\n",
       "      <td>440000</td>\n",
       "      <td>020</td>\n",
       "      <td>440117</td>\n",
       "      <td>川菜</td>\n",
       "      <td>川菜</td>\n",
       "      <td>4.5</td>\n",
       "      <td>[{'title': '', 'url': 'http://store.is.autonav...</td>\n",
       "      <td>13924024938</td>\n",
       "      <td>09:00-23:00</td>\n",
       "      <td>09:00-23:00</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>壹休盖饭</td>\n",
       "      <td>B0HRHG0RSP</td>\n",
       "      <td>113.679611,23.630517</td>\n",
       "      <td>餐饮服务;中餐厅;中餐厅</td>\n",
       "      <td>050100</td>\n",
       "      <td>广东省</td>\n",
       "      <td>广州市</td>\n",
       "      <td>从化区</td>\n",
       "      <td>温泉镇乌土村上围2队13号</td>\n",
       "      <td>440000</td>\n",
       "      <td>020</td>\n",
       "      <td>440117</td>\n",
       "      <td>盖饭</td>\n",
       "      <td>盖饭</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                name          id              location                type  \\\n",
       "0             喜洋洋烧烤城  B0FFKT56Q8  113.678474,23.628422        餐饮服务;中餐厅;中餐厅   \n",
       "1         港式住家饭(中大店)  B0H1M90UGD  113.679504,23.628108        餐饮服务;中餐厅;中餐厅   \n",
       "2          找餐时间(轻食店)  B0H31YY48Q  113.679695,23.628204        餐饮服务;中餐厅;中餐厅   \n",
       "3       巴老冒豆花冒菜(中大店)  B0HROCISXU  113.679739,23.628221        餐饮服务;中餐厅;中餐厅   \n",
       "4               牛哥烧烤  B0HROCM3MH  113.679809,23.628326  餐饮服务;中餐厅;特色/地方风味餐厅   \n",
       "5               桃缘瓦舍  B0IGC5BQCT  113.680297,23.627788        餐饮服务;中餐厅;中餐厅   \n",
       "6              歡喜烤鱼饭  B0HROCIT9Q  113.680349,23.627573        餐饮服务;中餐厅;中餐厅   \n",
       "7  99BARBECUE烤吧(中大店)  B0HROCMIX1  113.680449,23.629268  餐饮服务;中餐厅;特色/地方风味餐厅   \n",
       "8              湖边纸包鱼  B0FFL7NUA2  113.679861,23.630285    餐饮服务;中餐厅;四川菜(川菜)   \n",
       "9               壹休盖饭  B0HRHG0RSP  113.679611,23.630517        餐饮服务;中餐厅;中餐厅   \n",
       "\n",
       "  typecode pname cityname adname            address   pcode citycode  adcode  \\\n",
       "0   050100   广东省      广州市    从化区  博学路6号(广州南方学院南门口旁)  440000      020  440117   \n",
       "1   050100   广东省      广州市    从化区        温泉镇中山大学南方学院  440000      020  440117   \n",
       "2   050100   广东省      广州市    从化区            温泉镇中大南方  440000      020  440117   \n",
       "3   050100   广东省      广州市    从化区            温泉镇中大南方  440000      020  440117   \n",
       "4   050118   广东省      广州市    从化区        温泉镇中山大学南方学院  440000      020  440117   \n",
       "5   050100   广东省      广州市    从化区     温泉镇平岗村乌土平岗街29号  440000      020  440117   \n",
       "6   050100   广东省      广州市    从化区            乌土村中南公寓  440000      020  440117   \n",
       "7   050118   广东省      广州市    从化区           中大南方学院后门  440000      020  440117   \n",
       "8   050102   广东省      广州市    从化区             广州南方学院  440000      020  440117   \n",
       "9   050100   广东省      广州市    从化区      温泉镇乌土村上围2队13号  440000      020  440117   \n",
       "\n",
       "  business.rectag business.keytag business.rating  \\\n",
       "0              烤串              烤串             NaN   \n",
       "1             香港菜             香港菜             NaN   \n",
       "2              中餐              中餐             NaN   \n",
       "3              冒菜              冒菜             NaN   \n",
       "4              烤串              烤串             NaN   \n",
       "5              中餐              中餐             2.6   \n",
       "6              烤鱼              烤鱼             NaN   \n",
       "7              烧烤              烧烤             2.7   \n",
       "8              川菜              川菜             4.5   \n",
       "9              盖饭              盖饭             NaN   \n",
       "\n",
       "                                              photos business.tel  \\\n",
       "0                                                NaN          NaN   \n",
       "1                                                NaN          NaN   \n",
       "2                                                NaN          NaN   \n",
       "3                                                NaN          NaN   \n",
       "4                                                NaN          NaN   \n",
       "5                                                NaN          NaN   \n",
       "6                                                NaN          NaN   \n",
       "7                                                NaN          NaN   \n",
       "8  [{'title': '', 'url': 'http://store.is.autonav...  13924024938   \n",
       "9                                                NaN          NaN   \n",
       "\n",
       "  business.opentime_today business.opentime_week  \n",
       "0                     NaN                    NaN  \n",
       "1                     NaN                    NaN  \n",
       "2                     NaN                    NaN  \n",
       "3                     NaN                    NaN  \n",
       "4                     NaN                    NaN  \n",
       "5                     NaN                    NaN  \n",
       "6                     NaN                    NaN  \n",
       "7                     NaN                    NaN  \n",
       "8             09:00-23:00            09:00-23:00  \n",
       "9                     NaN                    NaN  "
      ]
     },
     "execution_count": 21,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pd.json_normalize(r.json()['pois'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "f5d4b236",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.8.8"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
